package simple.flow.exception;

import lombok.Getter;

/**
 * 通用异常类
 *
 * @author lhd
 * @since 2025/2/20
 */

@Getter
public class AppBootException extends RuntimeException {

    private final Integer code;

    public AppBootException(String message) {
        super(message);
        this.code = -1;
    }

    public AppBootException(Integer code, String message) {
        super(message);
        this.code = code;
    }

    public AppBootException(String message, Throwable cause) {
        super(message, cause);
        this.code = -1;
    }

    public AppBootException(Integer code, String message, Throwable cause) {
        super(message, cause);
        this.code = code;
    }
}
